package org.spark.api.constant;


/**
 * hbase中dy:下面各个表的字段
 */
public interface DyColumn {

    byte[] FAMILY = "r".getBytes();


    /**
     * 达人-Date-商品-直播间
     * dy:details-author-date-product-room
     */
    interface DetailsAuthorDateProductRoom {

        byte[] AUTHOR_ID = "ai".getBytes();

        byte[] NICKNAME = "nn".getBytes();

        byte[] PRODUCT_TITLE = "pt".getBytes();

        byte[] PRODUCT_COVER = "pc".getBytes();

        byte[] PRODUCT_URL = "pu".getBytes();

        byte[] PLATFORM = "p".getBytes();

        byte[] LABEL = "l".getBytes();

        byte[] FINAL_PRICE = "fp".getBytes();

        byte[] RATIO = "r".getBytes();

        byte[] VOLUME = "v".getBytes();

        byte[] AMOUNT = "a".getBytes();

        byte[] ROOM_TITLE = "rt".getBytes();

        byte[] ROOM_COVER = "rc".getBytes();

        byte[] STATUS = "s".getBytes();

        byte[] BEGIN_TIME = "bt".getBytes();

        byte[] FINISH_TIME = "ft".getBytes();

        byte[] TOTAL_USER = "tu".getBytes();

        byte[] USER_PEAK = "up".getBytes();

        byte[] GIFT_UV_COUNT = "guc".getBytes();

        byte[] FOLLOWER_COUNT = "fc".getBytes();

        byte[] IF_FETCH_VOLUME = "ifv".getBytes();

        byte[] VOLUME_SOURCE = "vol_sc".getBytes();

        byte[] ROOM_ID = "ri".getBytes();

        byte[] PRODUCT_ID = "pi".getBytes();

        byte[] DATE = "d".getBytes();
    }


    /**
     * 榜单的时间戳版本
     * rowKey：pack(榜单名，esIndex).pack(排行榜时间)
     */
    interface RankTimestampVersion {

        /**
         * 新的版本号
         */
        byte[] TIMESTAMP = "ts".getBytes();

        /**
         * 旧版本号
         */
        byte[] OLD_TIMESTAMP = "ots".getBytes();

    }

    /**
     * 商品关联视频销量
     * pack(productId).pack(date).pack(shareId)
     */
    interface DetailsProductDateAweme {

        /**
         * String
         */
        byte[] DATE = "d".getBytes();

        /**
         * String
         */
        byte[] PRODUCT_ID = "pi".getBytes();

        /**
         * String
         */
        byte[] AWEME_ID = "ai".getBytes();

        /**
         * Long
         */
        byte[] VOLUME = "vol".getBytes();

        /**
         * Double
         */
        byte[] AMOUNT = "amt".getBytes();

        /**
         * Integer
         */
        byte[] VOLUME_SOURCE = "vol_sc".getBytes();

        /**
         * Boolean
         */
        byte[] IF_FETCH_VOLUME = "ifv".getBytes();

        /**
         * Long
         */
        byte[] UNIQUE_VISITOR = "uv".getBytes();
    }


    /**
     * 商品-达人-直播间
     * dy:details-product-author-room
     * pack(DigestUtils.sha1Hex(productId)).pack(authorId).pack(roomId)
     */
    interface DetailsProductAuthorRoom {

        /**
         * 达人id
         */
        byte[] AUTHOR_ID = "ai".getBytes();

        /**
         * 销量
         */
        byte[] VOLUME = "v".getBytes();

        /**
         * 关联销售额
         */
        byte[] AMOUNT = "a".getBytes();


        /**
         * 商品id
         */
        byte[] PRODUCT_ID = "pi".getBytes();

        /**
         * 直播间id
         */
        byte[] ROOM_ID = "ri".getBytes();

    }


    /**
     * 商品-达人-视频
     * dy:details-product-author-aweme
     * pack(DigestUtils.sha1Hex(productId)).pack(authorId).pack(awemeId)
     */
    interface DetailsProductAuthorAweme {

        /**
         * 达人id
         */
        byte[] AUTHOR_ID = "ai".getBytes();

        /**
         * 销量
         */
        byte[] VOLUME = "v".getBytes();

        /**
         * 关联销售额
         */
        byte[] AMOUNT = "a".getBytes();

        /**
         * 商品id
         */
        byte[] PRODUCT_ID = "pi".getBytes();

        /**
         * 视频id
         */
        byte[] AWEME_ID = "awi".getBytes();
    }

    /**
     * 商品-达人-直播间
     * dy:details-product-date-author-room
     * pack(DigestUtils.sha1Hex(productId)).pack(authorId).pack(roomId)
     */
    interface DetailsProductDateAuthorRoom {

        /**
         * 达人id
         */
        byte[] AUTHOR_ID = "ai".getBytes();

        /**
         * 销量
         */
        byte[] VOLUME = "v".getBytes();

        /**
         * 关联销售额
         */
        byte[] AMOUNT = "a".getBytes();

        /**
         * 日期
         */
        byte[] DATE = "d".getBytes();

        /**
         * 商品id
         */
        byte[] PRODUCT_ID = "pi".getBytes();

        /**
         * 直播间id
         */
        byte[] ROOM_ID = "ri".getBytes();

    }


    /**
     * 商品-达人-视频
     * dy:details-product-date-author-aweme
     * pack(DigestUtils.sha1Hex(productId)).pack(date).pack(authorId).pack(awemeId)
     */
    interface DetailsProductDateAuthorAweme {

        /**
         * 达人id
         */
        byte[] AUTHOR_ID = "ai".getBytes();

        /**
         * 销量
         */
        byte[] VOLUME = "v".getBytes();

        /**
         * 关联销售额
         */
        byte[] AMOUNT = "a".getBytes();

        /**
         * 日期
         */
        byte[] DATE = "d".getBytes();

        /**
         * 商品id
         */
        byte[] PRODUCT_ID = "pi".getBytes();

        /**
         * 视频id
         */
        byte[] AWEME_ID = "awi".getBytes();
    }


    /**
     * 达人-Date-商品-视频
     * dy:details-author-date-product-aweme
     */
    interface DetailsAuthorDateProductAweme {

        byte[] AUTHOR_ID = "ai".getBytes();

        byte[] PRODUCT_TITLE = "pt".getBytes();

        byte[] PRODUCT_COVER = "pc".getBytes();

        byte[] PRODUCT_URL = "pu".getBytes();

        byte[] PLATFORM = "p".getBytes();

        byte[] LABEL = "l".getBytes();

        byte[] FINAL_PRICE = "fp".getBytes();

        byte[] RATIO = "r".getBytes();

        byte[] VOLUME = "v".getBytes();

        byte[] AMOUNT = "a".getBytes();

        byte[] AWEME_ID = "awi".getBytes();

        byte[] PRODUCT_ID = "pi".getBytes();

        byte[] DATE = "d".getBytes();
    }
}
